<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title>体验响应式 — 隆领</title>
		<link rel="shortcut icon" href="favicon.ico" type="image/x-icon">
		<meta content="" name="description">
		<meta content="" name="keywords">
		<meta name="viewport" id="viewport" content="width=device-width, initial-scale=1, minimum-scale=1, maximum-scale=1" />
		<meta name="apple-mobile-web-app-capable" content="yes" />
		<meta name="apple-mobile-web-app-status-bar-style" content="black" />
		<link href="static/css/web.css" rel="stylesheet" type="text/css">
		<link href="static/css/icon.css" rel="stylesheet" type="text/css">
		<script src="static/js/jquery-1.9.1.js"></script>
		<script src="static/js/common.js"></script>
	</head>
	<body style="overflow:hidden;">
		<div class="registerHead" id="mainHeader" style="display:none;">
			<div class="k1200 clearfix">
				<div class="newLogo">
					<a class="newLogoA" href="http://tuweia.cn/c/home/"><i class="ticon-logo"></i></a>
				</div>
				<div class="registerNav h3">
					<a href="javascript:;" data-width="100%" class="active" title="宽屏电脑"><i class="icon-screen"></i></a>
					<a href="javascript:;" data-width="1044" title="平板横屏"><i class="icon-x-pad"></i></a>
					<a href="javascript:;" data-width="788" title="平板竖屏"><i class="icon-tablet"></i></a>
					<a href="javascript:;" data-width="500" title="手机横屏"><i class="icon-x-mobile"></i></a>
					<a href="javascript:;" data-width="340" title="手机竖屏"><i class="icon-mobile"></i></a>
					<a href="javascript:;" id="showLink" target="_blank" title="打开网址"><i class="icon-link"></i></a>
				</div>
				<div class="siteUrl">
					<input type="text" placeholder="输入网址查看" id="getURL" style="border-right:none;" /><a href="javascript:;" id="button">查看</a>
				</div>
			</div>
		</div>
		<div class="registerMain">
			<div class="registerBox" id="iframeContainer">
				<iframe id="displayframe" name="displayframe"></iframe>
			</div>
		</div>
		<script>
			var givenURL = decodeURIComponent((RegExp('url=' + '(.+?)(&|$)').exec(location.search) || [, null])[1]);
			
			if (givenURL == 'null' || givenURL == null) {
				givenURL = 'http://' + window.location.host;
			};
			if (!givenURL.match(/^http/)) {
				givenURL = 'http://' + givenURL;
			};
			if ($(window).width() < 1024) {
				window.location.href = givenURL;
			} else {
				$('#mainHeader').show();;

				function updateframe() {
					if (!givenURL.match(/^http/)) {
						givenURL = 'http://' + givenURL;
					};
					$('#displayframe').attr('src',givenURL);
					$('#showLink').attr('href',givenURL);
				};
				$("#button").click(function() {
					givenURL = $("#getURL").val();
					updateframe();
				});
				$('a[data-width]').on(click, function() {
					$('a.active').removeClass('active');
					$(this).addClass('active');
					$('#iframeContainer').css('width', $(this).data('width'));
				});
				updateframe();
			}
		</script>
	</body>

</html>